{ INFORMATICS.MCCME.RU
  Problem statement: http://informatics.mccme.ru/moodle/mod/statements/view3.php?chapterid=313
  Verdict: Accepted
}
uses SysUtils, Math;
 
var
	n,k:longint;
 
function c(n,k:int64):int64;
begin
if (k=0) or (k=n) then result:=1 else result:=c(n-1,k-1)+c(n-1,k);
end;
 
begin
reset(input,'input.txt');
rewrite(output,'output.txt');
read(n,k);
write(c(n,k));
end.